
{***********************************************************}
{                                                           }
{      Informix esql "sqlda.h"                              }
{                                                           }
{      Translated to Object Pascal by                       }
{      Copyright (c) 2001-2008 Luxena Software Company      }
{      http://www.luxena.com                                }
{      e-mail: support@luxena.com                           }
{                                                           }
{***********************************************************}

unit IfxSqlda;

{$I lx.inc}

{$IFDEF VER140_OR_ABOVE}
  {$ALIGN 8}
{$ENDIF}

interface

uses
  IfxTypes;


type

  sqlvar_struct = record

    sqltype: int2; // variable type
    sqllen: int4; // length in bytes
    sqldata: PChar; // pointer to data
    sqlind: ^int2; // pointer to indicator
    sqlname: PChar; // variable name
    sqlformat: PChar; // reserved for future use
    sqlitype: int2; // ind variable type
    sqlilen: int2; // ind length in bytes
    sqlidata: PChar; // ind data pointer
    sqlxid: int4; // extended id type
    sqltypename: PChar; // extended type name
    sqltypelen: int2; // length of extended type name
    sqlownerlen: int2; // length of owner name
    sqlsourcetype: int2; // source type for distinct of built-ins
    sqlownername: PChar; // owner name
    sqlsourceid: int4; // extended id of source type

    // sqlilongdata is new.  It supports data that exceeds the 32k
    // limit.  sqlilen and sqlidata are for backward compatibility
    // and they have maximum value of <32K.

    sqlilongdata: PChar; // for data field beyond 32K
    sqlflags: int4; // for internal use only
    sqlreserved: Pointer; // reserved for future use
  end;

  PIfx_sqlvar = ^TIfx_sqlvar;
  TIfx_sqlvar = sqlvar_struct;



  PPIfx_sqlda = ^PIfx_sqlda;
  PIfx_sqlda = ^TIfx_sqlda;

  sql_da = record
    sqld: int2;
    sqlvar: PIfx_sqlvar;
    desc_name: array[0..18] of Char; //char desc_name[19];                                                              // descriptor name
    desc_occ: int2; // size of sqlda structure
    desc_next: PIfx_sqlda; // pointer to next sqlda struct
    reserved: Pointer; // reserved for future use
  end;

  TIfx_sqlda = sql_da;

implementation

end.